

package dateDype.instanceOF;

import dateDype.myDate;

public class empleado {    
    private Palo palo;
    private int rango;
    private dateDype.myDate[] dates = {
        new myDate(21, 06, 1989), new myDate(21, 06, 1989), new myDate(21, 06, 1989), 
        new myDate(21, 06, 1989), new myDate(21, 06, 1989), new myDate(21, 06, 1989), 
        new myDate(21, 06, 1989), new myDate(21, 06, 1989), new myDate(21, 06, 1989), 
        new myDate(21, 06, 1989), new myDate(21, 06, 1989), new myDate(21, 06, 1989), 
        new myDate(21, 06, 1989), new myDate(21, 06, 1989), new myDate(21, 06, 1989), 
        new myDate(21, 06, 1989), new myDate(21, 06, 1989), new myDate(21, 06, 1989), 
    };

    public empleado(Palo palo, int rango) {
        this.palo = palo;
        this.rango = rango;
    }      
    
    public String getName() {
        String name = "";        
        switch(palo) {
            case PICAS: name = palo._getName(); break;
            case CORAZONES: name = palo._getName(); break;
            case DIAMANTES: name = palo._getName(); break;
            case TREBOLES: name = palo._getName(); break;
                default: System.err.println("ERROR: Conjunto finito");
        }
        return name;
    }

    public Palo getPalo() {
        return palo;
    }

    public int getRango() {
        return rango;
    }        
}
